<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>JS 可拖动模态框</title>
    <link rel="stylesheet" href="index.css" />
    <script src="index.js"></script>
</head>
<body>
<button class="open">登录</button>
<div class="model-box">
    <div class="content">
        <div class="title">
            <span>登录</span>
            <i class="close">×</i>
        </div>
        <form action="#">
            <div class="form-input">
                <label for="username">请输入用户名</label>
                <input type="text" id="username" />
            </div>
            <div class="form-input">
                <label for="password">请输入密码</label>
                <input type="password" id="password" />
            </div>
            <div class="form-input">
                <button>登录</button>
            </div>
        </form>
    </div>
</div>
</body>
</html>
